package Zhouliu;
public class A {
    public int v=100;
    public int num;

    public int getV() {
        return v;
    }

    public void setV(int v) {
        this.v = v;
    }
    public int getNum() {
        return num;
    }

    public void setNum(int num) {
        this.num = num;
    }
    //定义一个无返回值类型的guess方法
    public void guess(){
        if(num>v){
            System.out.println("大了");
        }else if(num<v){
            System.out.println("小了");
        } else if(v==num){
            System.out.println("猜测成功");
        }
    }
}
